package svc

import (
	"github.com/zeromicro/go-zero/zrpc"
	"group/api/internal/config"
	"group/grouprpc/grouprpcclient"
)

type ServiceContext struct {
	Config   config.Config
	GroupRpc grouprpcclient.Grouprpc
}

func NewServiceContext(c config.Config) *ServiceContext {
	return &ServiceContext{
		Config:   c,
		GroupRpc: grouprpcclient.NewGrouprpc(zrpc.MustNewClient(c.GroupRpc)),
	}
}
